/*
 * @文件描述: 示波器model的presenter层
 * @版本: 
 * @作者: 周晨阳
 * @Date: 2021-01-20 13:59:02
 * M_开头的都是view层调用的，用于和model层通信
 * V_开头的都是Model层调用的，用于和view层通信
 */
#ifndef OSCILLOSCOPEPRE_H
#define OSCILLOSCOPEPRE_H
//#include <stdint.h>
#include "GUI.h"
#include "typedef.h"
/********/
void M_IncreaseSamplingRate(void);
void M_DecreaseSamplingRate(void);
void M_IncreaseV_Scale(void);
void M_DecreaseV_Scale(void);
//不同参数显示开关
void M_Function(unsigned char function, unsigned char param);
void M_Auto(void);
void M_Run_Stop(void);
void M_changeTirggerType(void);

void V_setH_Scale(const char *str);
void V_setV_Scale(const char *str);
void V_Function(unsigned char function, unsigned char param);
void V_setGraph(GUI_POINT *data, unsigned int size);
void V_OscillUI_Init(void);
void V_drawOscilGraph(void);
void V_setGraphSize(int size);

//设置run/stop按钮颜色，以指示当前状态
void V_setState(unsigned char state);

void V_showCursor(unsigned char which);
void V_hideCursor(unsigned char which);
void V_setCursorPos(unsigned char which, unsigned int posX);
void V_setCursor(Cursor *c);
void V_setOscillDataList(OscillInfo *list);
void V_setV_arrowPos(int pos);
void V_setH_arrowPos(int pos);
void V_setTrigger(uint8_t triggerType, float voltage);
void V_setTriggerState(uint8_t state);
void V_setMenuInfo(MenuInfo *m, uint8_t itemCnt);
void V_setWaveWinInfo(float width, int pos);
void V_setCursorListInfo(OscillInfo *p);
void V_showToastInfo(char * info,uint8_t sec);
#endif